import {createStore} from 'vuex'

//创建实例化对象 
const store = createStore({
    state(){
        return{
            count:0
        }
    },
    getters:{
        tenTimes:(state)=>{
            return state.count*10
        }
    },
    mutations:{
        increment(state,playload){
            state.count = playload.count
        }
    }
})

export default store;